package com.zjxf.repository;

import com.zjxf.base.bean.po.CmsStory;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;

import java.util.Optional;

/**
 * 长征故事
 *
 * @author ZhangWei
 * @date 2021/4/6/006 19:10
 */
public interface CmsStoryRepository extends JpaRepository<CmsStory, Long>, JpaSpecificationExecutor<CmsStory> {

    /**
     * 根据id与删除状态
     * @param id
     * @param deleteState
     * @return
     */
    Optional<CmsStory> findByIdAndDeleteState(Long id, Integer deleteState);
}
